package core.generator.service;

import freemarker.template.Configuration;
import freemarker.template.Template;

import java.util.Map;

/**
 * @author Long
 * @version 1.0
 * @description:
 * @title GeneratorService
 * @date 2021/3/6 10:12
 */
public interface GeneratorService {

    /**
     * 根据数据元生成
     * @param data
     * @param templatePath
     * @param outPath
     */
    void codeGenerator(Map<String, Object> data, String templatePath, String outPath);

    void codeGenerator(Map<String, Object> data, String outPath);

    void codeGenerator(Map<String, Object> data);

    String getOutFileName(Map<String, Object> data, String templateFileName, Configuration configuration);

    String getTemplatePath(String path);

    Template getTemplate(String templateFileName, Configuration configuration);

    Configuration getConfiguration(String templatePath);
}
